package net.osweb.crm.modules.core.bean;

import javax.persistence.Column;

/**
 * UsermailserverId entity. @author MyEclipse Persistence Tools
 */

public class UserEmailServerId implements java.io.Serializable {

	/**
	 * 
	 */
	private static final long serialVersionUID = -8642515436226040438L;
	private Integer id;
	private Integer userid;

	// Constructors

	/** default constructor */
	public UserEmailServerId() {
	}

	/** full constructor */
	public UserEmailServerId(Integer id, Integer userid) {
		this.id = id;
		this.userid = userid;
	}

	// Property accessors

	@Column(name = "id", nullable = false)
	public Integer getId() {
		return this.id;
	}

	public void setId(Integer id) {
		this.id = id;
	}

	@Column(name = "userid", nullable = false)
	public Integer getUserid() {
		return this.userid;
	}

	public void setUserid(Integer userid) {
		this.userid = userid;
	}

	public boolean equals(Object other) {
		if ((this == other))
			return true;
		if ((other == null))
			return false;
		if (!(other instanceof UserEmailServerId))
			return false;
		UserEmailServerId castOther = (UserEmailServerId) other;

		return ((this.getId() == castOther.getId()) || (this.getId() != null
				&& castOther.getId() != null && this.getId().equals(
				castOther.getId())))
				&& ((this.getUserid() == castOther.getUserid()) || (this
						.getUserid() != null && castOther.getUserid() != null && this
						.getUserid().equals(castOther.getUserid())));
	}

	public int hashCode() {
		int result = 17;

		result = 37 * result + (getId() == null ? 0 : this.getId().hashCode());
		result = 37 * result
				+ (getUserid() == null ? 0 : this.getUserid().hashCode());
		return result;
	}

}